<ul>
<?php foreach ($data as $item): ?>
<li><a href="?action=article&amp;id=<?php echo $item->id; ?>"><?php echo $item->title; ?></a></li>
<?php endforeach; ?>
</ul>